package com.example.friendcash.database.services.implementation;

import com.example.friendcash.database.dao.interfaces.IDaoFactory;
import com.example.friendcash.database.services.interfaces.*;

public final class ServiceFactory implements IServiceFactory {

    private final IDaoFactory daoFactory;

    public ServiceFactory(IDaoFactory daoFactory) {
        this.daoFactory = daoFactory;
    }

    @Override
    public IEventService createEventService() {
        return new EventService(daoFactory);
    }

    @Override
    public IFriendService createFriendService() {
        return new FriendService(daoFactory);
    }

    @Override
    public IPartService createPartService() {
        return new PartService(daoFactory);
    }

    @Override
    public IPaymentService createPaymentService() {
        return new PaymentService(daoFactory);
    }

}
